Engineering Systems Design 2 Notes
Table of Contents
Bits, Bytes and Codes
Basics
Boolean constants (0/1) are abstractions of high and low voltage levels.
Variable length encoding
| char | prob | fix length code | var length code |
|---|---|---|---|
| a | 0.5 | 000 | 0 |
| b | 0.3 | 001 | 10 |
| c | 0.1 | 010 | 110 |
| d | 0.05 | 011 | 1110 |
| e | 0.05 | 100 | 1111 |
Truth tables
3 in, 1 out
| A | B | C | X |
|---|---|---|---|
| 0 | 0 | 0 | |
| 0 | 0 | 1 | |
| 0 | 1 | 0 | |
| 0 | 1 | 1 | |
| 1 | 0 | 0 | |
| 1 | 0 | 1 | |
| 1 | 1 | 0 | |
| 1 | 1 | 1 |
The number of 3-input, 1-output Boolean functions is equal to the number of ways of filling in the number of 8 outputs in the truth table. \[N=2^8=256\]
Sum of Products form
Simplified algebraic form making it easy to convert to circuit diagrams.
- \((A+B)\overline{C}=A\overline{C}+B\overline{C}\)
- \(A+\overline{BC}=A+\overline{B}+\overline{C}\)
- \(AB+C(\overline{A}+B)=AB+C\overline{A}+CB\)
SoP form leads to AND-OR circuits
\begin{circuitikz} \draw (0,0) node[and port] (A) (0,2) node[and port] (B) (0,4) node[and port] (C) (2,2) node[or port] (D); (A.out) -- (D.in 1); (B.out) -- (D.in 2); % (C.out) -- (D.in 3); \end{circuitikz} \begin{circuitikz} \draw (0,2) node (myand1) [xshift=1cm,and port] {} (myand1.out) node [anchor=south west] {\it A.B} (myand1.in 1) node (A1) [anchor=east,xshift=-1cm] {A} (myand1.in 2) node (B1) [anchor=east,xshift=-1cm,yshift=-.7cm] {B} (0,0) node (mynot1) [not port, scale=.5] {} (mynot1.out) node [anchor=south west] {$\bar{B}$} (2.5,-.280) node (myor1) [or port] {} (myor1.out) node [anchor=south west,xshift=.05cm] {$\bar{B}\texttt{+}C$} (4,1.72) node (myor2) [or port] {} (myor1.in 2) node (C1) [anchor=east,xshift=-2.5cm] {C} (myor2.out) node [anchor=south west] {{\it A.B}\texttt{+}$(\bar{B}$\texttt{+}$C)$}; \draw (myor2.out) -- ++(1cm,0); \draw (myand1.in 2) |- (mynot1.in); \draw (mynot1.out) -| (myor1.in 1); \draw (myand1.out) -- (myor2.in 1); \draw (myor1.out) -- (myor2.in 2); \draw (myand1.in 1) -- (A1); \foreach \Point in {(A1),(B1), (C1)}{ \node [xshift=.2cm] at \Point {\textbullet}; } \node [xshift=1.25cm] at (B1) {$\bullet$}; \node [xshift=1cm] at (myor2.out) {$\bullet$}; \draw (B1) -- ++(1.25cm,0); \draw (myor1.in 2) -- (C1); \end{circuitikz}